package org.jsets.rpc.utils;

import java.util.UUID;

public class StringKit {
	
	public static String getUUID() {
		UUID uuid = UUID.randomUUID();
		return uuid.toString().replaceAll("-", "");
	}

	public static String getUUID(final String fix) {
		UUID uuid = UUID.randomUUID();
		return fix + "_" + (uuid.toString().replaceAll("-", ""));
	}

	public static boolean isEmpty(final String string) {
		if (string == null || "".equals(string) || string == "null") {
			return Boolean.TRUE;
		}
		return Boolean.FALSE;
	}

	public static boolean isNotEmpty(final String string) {
		return !isEmpty(string);
	}
}
